<span>{{ $priceSection }}</span>
@if ($status !== 2 && $subPrice == 0 && !prod() && $plug === 0)
    <a href="javascript:;" class="grid-row-view" data-toggle="modal" data-target="#spec_price_list{{ $id }}">
        修改价格
    </a>
    <div class="modal fade" id="spec_price_list{{ $id }}" tabindex="-1" role="dialog" aria-hidden="true">
        <div class="modal-dialog modal-lg">
            <div class="modal-content">
                <div class="modal-header">
                    <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
                </div>
                <div class="form-group" style="padding: 30px;">
                    <div class="col-sm-2">
                        <select class="form-control priceSelect">
                            <option value="0">统一价</option>
                            <option value="1">+</option>
                            <option value="2">-</option>
                        </select>
                    </div>
                    <div class="col-sm-2">
                        <input type="text" class="form-control batchPriceUnderlined" placeholder="原价" maxlength="10"
                            onfocus="checkDecimal(this)" onkeyup="checkDecimal(this)">
                    </div>
                    <div class="col-sm-2">
                        <input type="text" class="form-control batchPrice" placeholder="优惠价" maxlength="10"
                            onfocus="checkDecimal(this)" onkeyup="checkDecimal(this)">
                    </div>
                    <div class="col-sm-2">
                        <button type="button" class="btn btn-primary" onclick="batchPrice(this)">批量修改</button>
                    </div>
                </div>
                <table class="table table-bordered" id="{{ $serialNumber }}">
                    <thead>
                        <tr>
                            <th scope="col">规格信息</th>
                            <th scope="col">当前原价</th>
                            <th scope="col">当前优惠价</th>
                            <th scope="col">改后原价</th>
                            <th scope="col">改后优惠价</th>
                        </tr>
                    </thead>
                    <tbody>
                        @foreach ($specs as $v)
                            <tr class="spec-price-tr">
                                <td class="spec-info">
                                    <input type="hidden" class="spec-price-hidden" value="{{ $v->ps_id }}">
                                    <input type="hidden" class="old-under" value="{{ $v->ps_price_underlined }}">
                                    <input type="hidden" class="old-price" value="{{ $v->ps_price }}">
                                    <img src="{{ fileIdToUrl($v->ps_avatar ?? $defaultImg) }}" width="30"
                                        alt="">
                                    <span>ID:{{ $v->serial_number }}<br />{{ $v->ps_name }}</span>
                                </td>
                                <td>{{ $v->ps_price_underlined }}</td>
                                <td>{{ $v->ps_price }}</td>
                                <td><input type="text" class="form-control marketPrice"
                                        value="{{ delZero($v->ps_price_underlined) }}" onfocus="checkDecimal(this)"
                                        onkeyup="checkDecimal(this)" maxlength="10"></td>
                                <td><input type="text" class="form-control price"
                                        value="{{ delZero($v->ps_price) }}" onfocus="checkDecimal(this)"
                                        onkeyup="checkDecimal(this)" maxlength="10"></td>
                            </tr>
                        @endforeach
                    </tbody>
                </table>
                <div class="modal-footer">
                    <button type="button" class="btn btn-primary"
                        onclick="saveSpecPrice('{{ $serialNumber }}','{{ $newAuth }}')">确定
                    </button>
                </div>
            </div>
        </div>
    </div>
@endif
